home *** CD-ROM | disk | FTP | other *** search
/ CU Amiga Super CD-ROM 25 / CU Amiga Magazine's Super CD-ROM 25 (1998)(EMAP Images)(GB)(Track 1 of 2)[!][issue 1998-08].iso / CUCD / Programming / ixemul / sdk / man / cat3 / ftok.0 < prev    next >
Encoding:
Text File  |  1998-06-15  |  1.8 KB  |  45 lines

  1.  
  2. ftok(3)                    UNIX Programmer's Manual                    ftok(3)
  3.  
  4. NNAAMMEE
  5.      ffttookk - create IPC indentifier from path name
  6.  
  7. SSYYNNOOPPSSIISS
  8.      ##iinncclluuddee <<ssyyss//ttyyppeess..hh>>
  9.      ##iinncclluuddee <<ssyyss//iippcc..hh>>
  10.  
  11.      _k_e_y___t
  12.      ffttookk(_c_o_n_s_t _c_h_a_r _*_p_a_t_h, _c_h_a_r _i_d);
  13.  
  14. DDEESSCCRRIIPPTTIIOONN
  15.      The ffttookk() function attempts to create a unique key suitable for use with
  16.      the msgget(2),  semget(2) and shmget(2) functions given the _p_a_t_h of an
  17.      existing file and a user-selectable _i_d.
  18.  
  19.      The specified _p_a_t_h must specify an existing file that is accessible to
  20.      the calling process or the call will fail.  Also, note that links to
  21.      files will return the same key, given the same _i_d.
  22.  
  23. RREETTUURRNN VVAALLUUEESS
  24.      The ffttookk() function will return -1 if _p_a_t_h does not exist or if it cannot
  25.      be accessed by the calling process.
  26.  
  27. SSEEEE AALLSSOO
  28.      msgget(2),  semget(2),  shmget(2)
  29.  
  30. HHIISSTTOORRYY
  31.      The ffttookk() function originate with System V and is typically used by pro-
  32.      grams that use the System V IPC routines.
  33.  
  34. AAUUTTHHOORR
  35.      Thorsten Lockert <tholo@sigmasoft.com>
  36.  
  37. BBUUGGSS
  38.      The returned key is computed based on the device and inode of the speci-
  39.      fied _p_a_t_h in combination with the given _i_d. Thus is is quite possible for
  40.      the routine to return duplicate keys given that those fields are not 8-
  41.      and 16-bit quantities like they were on System V based systems where this
  42.      library routine's ancestor were originally created.
  43.  
  44. BSD Experimental                 June 24, 1994                               1
  45.